<?php

namespace mpend\modules\issue\models;

use Yii;

/**
 * 首页默认面板信息
 *
 * @author emhome <emhome@163.com>
 * @since 1.0
 */
class DashboardLogic extends \common\logics\DashboardLogic {

    /**
     * @var array top pages
     */
    public $messages = 0;

    /**
     * @var array top pages
     */
    public $banner = null;

    /**
     * @var array The Function navigation menu
     */
    public $options = [];

    /**
     * Set top pages
     * @inheritdoc
     */
    protected function setBanner() {
        return [
            'title' => '需求发布中心',
            'thumb' => '/static/images/eventlogo.png',
            'description' => '有需要从这里开始',
            'type' => 'cell',
        ];
    }

    /**
     * Set top pages
     * @inheritdoc
     */
    protected function setOptions() {
        return [
            [
                'title' => '创建新需求',
                'thumb' => '/static/icons/history.png',
                'description' => '快速发布需求信息',
                'icon' => 'add-o',
                'mplink' => [
                    'allow' => 'authented',
                    'tips' => '发布需求',
                    'type' => 'push',
                    'route' => '/pages/publish/main'
                ],
            ],
//            [
//                'title' => '需求动态',
//                'thumb' => '/static/icons/dynamic.png',
//                'description' => '最近没有需求的变动消息',
//                'icon' => 'aim',
//                'mplink' => null,
//            ],
        ];
    }

}
